home *** CD-ROM | disk | FTP | other *** search
Text File | 1997-06-28 | 1.5 KB | 72 lines | [TEXT/CWIE] |
- // Face.cp
-
- #ifndef Face_h
- #include "Face.h"
- #endif
- #ifndef GrafPortObject_h
- #include "GrafPortObject.h"
- #endif
-
- bool Face::operator==( const Face& f ) const
- {
- return font == f.font
- && size == f.size
- && style == f.style;
- }
-
- Face Face::System( ScriptCode script )
- {
- uint32 packed = GetScriptVariable( script, smScriptSysFondSize );
- return Face( FontNumber::Make( Word1( packed ) ),
- FontSize::Make( Word0( packed ) ),
- normal );
- }
-
- Face Face::Application( ScriptCode script )
- {
- uint32 packed = GetScriptVariable( script, smScriptAppFondSize );
- return Face( FontNumber::Make( Word1( packed ) ),
- FontSize::Make( Word0( packed ) ),
- normal );
- }
-
- Face Face::Small( ScriptCode script )
- {
- uint32 packed = GetScriptVariable( script, smScriptSmallFondSize );
- return Face( FontNumber::Make( Word1( packed ) ),
- FontSize::Make( Word0( packed ) ),
- normal );
- }
-
- Face Face::Help( ScriptCode script )
- {
- uint32 packed = GetScriptVariable( script, smScriptHelpFondSize );
- return Face( FontNumber::Make( Word1( packed ) ),
- FontSize::Make( Word0( packed ) ),
- normal );
- }
-
- const Face& Face::System()
- {
- static Face face = System( smSystemScript );
- return face;
- }
-
- const Face& Face::Application()
- {
- static Face face = Application( smSystemScript );
- return face;
- }
-
- const Face& Face::Small()
- {
- static Face face = Small( smSystemScript );
- return face;
- }
-
- const Face& Face::Help()
- {
- static Face face = Help( smSystemScript );
- return face;
- }
-